<?php
/**
 * Created by jinqiang on 2024/12/31 10:16.
 * Copyright (c) 2024, Your Company. All rights reserved.
 */


namespace App\Http\Controllers\Callback;


use App\Http\Controllers\Controller;
use App\Http\Services\Callback\EqbService;
use Illuminate\Http\Request;

class EqbController extends Controller
{
    //签署回调
    public function sign(Request $request, EqbService $eqbService)
    {
        $this->validate($request, [
            'action' => 'required|in:SIGN_FLOW_UPDATE,SIGN_FLOW_FINISH',
            'authorizedAccountId' => 'required',
            'accountId' => 'required',
            'flowId' => 'required'
        ]);
        $param = $request->all();
        info("签署回调", [$param]);
        $res = $eqbService->sign($param);
        return '{"msg":"success","code":"200"}';
    }
}
